{
  LW Modeler -- LightWave Modeler Global State

  This header contains declarations for the global services and
  internal states of the Modeler host application.

  Based on lwmodeler.h which is:
  Copyright 1999, NewTek, Inc.
}

{
  Copyright 2012, Jameel Halabi

  This unit is part of the BlaiseWave wrapper,
  which is licensed under the BSD 2-Clause license (see licenses/license.txt).
}
unit LW_Modeler;

{$mode objfpc}{$H+}

interface

uses
  LW_Types;

const
  OPLYR_PRIMARY	 = 0 ;
  OPLYR_FG	 = 1 ;
  OPLYR_BG	 = 2 ;
  OPLYR_SELECT	 = 3 ;
  OPLYR_ALL	 = 4 ;
  OPLYR_EMPTY	 = 5 ;
  OPLYR_NONEMPTY = 6 ;

  OPSEL_GLOBAL	 = 0 ;
  OPSEL_USER	 = 1 ;
  OPSEL_DIRECT	 = 2 ;

  LWSTATEQUERYFUNCS_GLOBAL = 'LWM: State Query 3';

  LWM_MODE_SELECTION = 0 ;
  LWM_MODE_SYMMETRY  = 1 ;
  LWM_VMAP_WEIGHT    = 0 ;
  LWM_VMAP_TEXTURE   = 1 ;
  LWM_VMAP_MORPH     = 2 ;

  LWFONTLISTFUNCS_GLOBAL = 'LWM: Font List';

type

  TEltOpLayer  = Integer ;
  TEltOpSelect = Integer ;

  PLWStateQueryFuncs = ^TLWStateQueryFuncs ;
  TLWStateQueryFuncs = record
    NumLayers : function
                ( const Void                 ) : Integer ;
    LayerMask : function
                (       OpLayer : TEltOpLayer) : Uint32  ;
    Surface   : function
                ( const Void                 ) : PChar   ; // const
    BBox      : function
                (       OpLayer : TEltOpLayer;
                        Minmax  : PDouble    ) : Uint32  ;
    LayerList : function
                (       OpLayer : TEltOpLayer;
                  const ObjName : PChar      ) : PChar   ; // const
    Object_   : function
                ( const Void                 ) : PChar   ; // const
    Mode      : function
                (       Setting : Integer    ) : Integer ;
    VMap      : function
                (       Index   : Integer    ;
                        LWID    : PLWID      ) : PChar   ; // const
  end;

  PLWFontListFuncs = ^TLWFontListFuncs ;
  TLWFontListFuncs = record
    Count     : function
                ( const Void                  ) : Integer ;
    Index     : function
                ( const Name     : PChar      ) : Integer ;
    Load      : function
                ( const Filename : PChar      ) : Integer ;
    Clear     : procedure
                (       InIndex  : Integer    ) ;
  end;

implementation

end.

